package com.zhiling.www.feignclient;

import com.zhiling.www.entity.Result;
import com.zhiling.www.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient(value = "stock-user",fallback= UserClientImpl.class)
public interface UserClient {

    //根据用户id更新余额
    @PostMapping("/user/updatamoney")
    Result updateMoney(User user);

    //根据用户id更新余额
    @PostMapping("/user/finduser")
    Result findUser(@RequestParam("userId") Integer userId);
}
